home *** CD-ROM | disk | FTP | other *** search
/ Software USA 4 #8 / Software USA Volume 4.08.iso / mac / LifeStyles / ComicBase / ComicBase.sea / ComicBase 3 Mac Demo / ComicBase 3 Demo.rsrc / LENS_137_ComicBase Statistics < prev    next >
Text File  |  1998-02-04  |  17KB  |  401 lines

  1. ItemType: WIND
  2. Rect: 272,237,751,530
  3. Style: Window
  4. HasTitleBar: TRUE
  5. HasZoomBox: TRUE
  6. HasCloseBox: TRUE
  7. HasGrowBox: TRUE
  8. MinSize: 479,232
  9. MaxSize: 479,1285
  10. Name: ComicBase Statistics
  11. WhiteColor: -8739,-8739,-8739
  12. Script: --on windowEvent  wdID,wdName,objNo,objName,objValue¬¬global gWindowPositions¬¬Global grandtotalCurrentYearValue¬Global grandTotalPrice¬Global grandTotalQtyInStock¬Global grandTotalCost¬Global gNoDescriptions¬Global gNoPictures¬Global gPublisherBreakdown¬Global gNoDescriptionsList¬global gNoPicturesList¬¬global kCurrPrefix, kCurrSuffix¬global kFormatString, kIntFormatString, kDecimalFormatString, kCurrFormatString¬global gCalcCollectionValueFigures¬global gCalcMissingDescriptions¬global gCalcMissingPictures¬global gCalcPublisherBreakdowns¬¬¬---------------------¬-- This is window #5¬---------------------¬¬if objValue="Open" then ¬  -- Restore old window position¬  put OldWindowPosition(5) into windowRect¬  if windowRect = empty then centerWindow wdName¬  else wsSet wdID,"0","Rect",windowRect¬  if there is a menuItem "Close" of menu "File" then¬    Enable menuItem "Close" of menu "File"¬  end if¬  ¬  -- Initialize the calculation variables in case the user choose "Print" immediately¬  put true into gCalcCollectionValueFigures¬  put true into gCalcMissingDescriptions¬  put true into gCalcMissingPictures¬  put true into gCalcPublisherBreakdowns¬  ¬  if grandTotalQtyInStock > 0 then¬    put grandTotalPrice / grandTotalQtyInStock into avgPrice¬    put grandTotalCost / grandTotalQtyInStock into avgCost¬    put grandtotalCurrentYearValue / grandTotalQtyInStock into avgValue¬  else¬    put 0 into avgPrice¬    put 0 into avgCost¬    put 0 into avgValue¬  end if¬  ¬  set the properties of window "ComicBase Statistics" to "TotalComics_Text:" & NumFormat(grandTotalQtyInStock,kIntFormatString) & return & "TotalTitles_Text:" & NumFormat(the number of cards of bg "Title",kIntFormatString) & return & "CollectionValue_Text:" & kCurrPrefix & NumFormat(grandtotalCurrentYearValue,kDecimalFormatString) & kCurrSuffix & return & "AvgValueComic_Text:" & kCurrPrefix & NumFormat(avgValue,kDecimalFormatString) & kCurrSuffix & return & "CollectionPrice_Text:" & kCurrPrefix & NumFormat(grandTotalPrice,kDecimalFormatString) & kCurrSuffix & return & "AvgPriceComic_Text:" & kCurrPrefix & NumFormat(avgPrice,kDecimalFormatString) & kCurrSuffix & return & "TotalCost_Text:" & kCurrPrefix & NumFormat(grandTotalCost,kDecimalFormatString) & kCurrSuffix & return & "AvgCostComic_Text:" & kCurrPrefix & NumFormat(avgCost,kDecimalFormatString) & kCurrSuffix & return & "TotalMarkup_Text:" & kCurrPrefix & NumFormat((grandTotalPrice - grandTotalCost),kDecimalFormatString) & kCurrSuffix & return & "AvgMarkupComic_Text:" & kCurrPrefix & NumFormat((avgPrice - avgCost),kDecimalFormatString) & kCurrSuffix & return & "NoDescriptions_Text:" & NumFormat(gNoDescriptions,kIntFormatString) & return & "NoPictures_Text:" & NumFormat(gNoPictures,kIntFormatString) & return ¬  ¬  set "TitlesByPublisher_Text" of window "ComicBase Statistics" to gPublisherBreakdown¬  ¬  ¬else if objValue="Close" then ¬  -- save the window position¬  put "5" & tab & wdName & tab & wsGet(wdID,"0","Rect") into line 5 of gWindowPositions¬  if there is a menuItem "Close" of menu "File" then¬    disable menuItem "Close" of menu "File"¬  end if¬  ¬else if objValue="Suspend" then ¬  put frontWindow() into theFrontID¬  if wsGet(theFrontID,"0","HasCloseBox") <> "true" then¬    if there is a menuItem "Close" of menu "File" then¬      disable menuItem "Close" of menu "File"¬    end if¬  end if¬  ¬else if objValue="Resume" then ¬  if there is a menuItem "Close" of menu "File" then¬    enable menuItem "Close" of menu "File"¬  end if¬  ¬end if¬¬--end windowEvent¬
  13. Params: i8_Text
  14. Result: i2_Hilite¬i3_Hilite¬i4_Hilite
  15.  
  16. ItemType: TEXT
  17. Rect: 31,16,104,28
  18. TextFont: Geneva
  19. TextSize: 9
  20. WhiteColor: -8739,-8739,-8739
  21. TextStyle: Bold
  22. Text: Total Titles:
  23.  
  24. ItemType: TEXT
  25. Rect: 25,30,104,42
  26. TextFont: Geneva
  27. TextSize: 9
  28. Disabled: TRUE
  29. WhiteColor: -8739,-8739,-8739
  30. TextStyle: Bold
  31. Text: Total Comics:
  32.  
  33. ItemType: BOX
  34. Rect: 207,24,466,106
  35. Pen: White
  36.  
  37. ItemType: BOX
  38. Rect: 15,64,172,106
  39. Pen: White
  40.  
  41. ItemType: TEXT
  42. Rect: 214,43,298,55
  43. TextFont: Geneva
  44. TextSize: 9
  45. Disabled: TRUE
  46. WhiteColor: -8739,-8739,-8739
  47. TextStyle: Bold
  48. Text: Current Value:
  49.  
  50. ItemType: TEXT
  51. Rect: 265,71,298,83
  52. TextFont: Geneva
  53. TextSize: 9
  54. Disabled: TRUE
  55. WhiteColor: -8739,-8739,-8739
  56. TextStyle: Bold
  57. Text: Cost:
  58.  
  59. ItemType: TEXT
  60. Rect: 220,57,298,69
  61. TextFont: Geneva
  62. TextSize: 9
  63. Disabled: TRUE
  64. WhiteColor: -8739,-8739,-8739
  65. TextStyle: Bold
  66. Text: Asking Price:
  67.  
  68. ItemType: TEXT
  69. Rect: 107,16,161,28
  70. TextFont: Geneva
  71. TextSize: 9
  72. AutoSize: FALSE
  73. Name: TotalTitles
  74. WhiteColor: -8739,-8739,-8739
  75. TextAlign: Right
  76. Text: 3,431
  77. Balloon: This is the number of different titles in the ComicBase.
  78.  
  79. ItemType: TEXT
  80. Rect: 107,30,161,42
  81. TextFont: Geneva
  82. TextSize: 9
  83. AutoSize: FALSE
  84. Disabled: TRUE
  85. Name: TotalComics
  86. WhiteColor: -8739,-8739,-8739
  87. TextAlign: Right
  88. Text: 0
  89. Balloon: This is the total number of comics you have in your collection.
  90.  
  91. ItemType: TEXT
  92. Rect: 301,43,371,55
  93. TextFont: Geneva
  94. TextSize: 9
  95. AutoSize: FALSE
  96. Disabled: TRUE
  97. Name: CollectionValue
  98. WhiteColor: -8739,-8739,-8739
  99. TextAlign: Right
  100. Text: $0.00
  101. Balloon: This is the value of all the comics in your collection, as figured by the most current year you’ve entered price information for.
  102.  
  103. ItemType: TEXT
  104. Rect: 301,71,371,83
  105. TextFont: Geneva
  106. TextSize: 9
  107. AutoSize: FALSE
  108. Disabled: TRUE
  109. Name: TotalCost
  110. WhiteColor: -8739,-8739,-8739
  111. TextAlign: Right
  112. Text: $0.00
  113. Balloon: This is the combined cost of all the comics in your collection.
  114.  
  115. ItemType: TEXT
  116. Rect: 381,57,450,69
  117. TextFont: Geneva
  118. TextSize: 9
  119. AutoSize: FALSE
  120. Disabled: TRUE
  121. Name: AvgPriceComic
  122. WhiteColor: -8739,-8739,-8739
  123. TextAlign: Right
  124. Text: $0.00
  125. Balloon: This is the average asking price of each comic in your collection.
  126.  
  127. ItemType: TEXT
  128. Rect: 381,71,450,83
  129. TextFont: Geneva
  130. TextSize: 9
  131. AutoSize: FALSE
  132. Disabled: TRUE
  133. Name: AvgCostComic
  134. WhiteColor: -8739,-8739,-8739
  135. TextAlign: Right
  136. Text: $0.00
  137. Balloon: This is the average cost of each of the  comics in your collection.
  138.  
  139. ItemType: TEXT
  140. Rect: 301,85,371,97
  141. TextFont: Geneva
  142. TextSize: 9
  143. AutoSize: FALSE
  144. Disabled: TRUE
  145. Name: TotalMarkup
  146. WhiteColor: -8739,-8739,-8739
  147. TextAlign: Right
  148. Text: $0.00
  149. Balloon: This is the combined mark-up of all the comics in your collection (the asking price - your cost).
  150.  
  151. ItemType: TEXT
  152. Rect: 381,85,450,97
  153. TextFont: Geneva
  154. TextSize: 9
  155. AutoSize: FALSE
  156. Disabled: TRUE
  157. Name: AvgMarkupComic
  158. WhiteColor: -8739,-8739,-8739
  159. TextAlign: Right
  160. Text: $0.00
  161. Balloon: This is the average mark-up of each of the comics in your collection (the asking price - your cost).
  162.  
  163. ItemType: PUSH
  164. Rect: 355,266,447,286
  165. AutoSize: FALSE
  166. Name: Calculate…
  167. DefaultItem: TRUE
  168. Balloon: Click here to recalculate the totals for all the fields in the ComicBase. This may take awhile, depending on the size of your collection.
  169. Script: --on mouseUp  wdID,wdName,objNo,objName,objValue¬Global grandtotalCurrentYearValue¬Global grandTotalPrice¬Global grandTotalQtyInStock¬global grandTotalCost¬Global gNoDescriptions, gNoPictures¬Global StopIt¬Global gPublisherBreakdown¬global kDecimalSepChar, kThousandsSepChar, kCurrSymbol, kCurrSymIsBefore, kCurrPrefix, kCurrSuffix¬global kFormatString, kIntFormatString, kDecimalFormatString, kCurrFormatString¬global gCalcCollectionValueFigures¬global gCalcPublisherBreakdowns¬global gCalcMissingDescriptions¬global gCalcMissingPictures¬global theStuff¬¬put (not (gCalcCollectionValueFigures)) into pubBreakdownDisabled¬put (not ((gCalcCollectionValueFigures) or (gCalcMissingDescriptions) or (gCalcMissingPictures))) into okDisabled¬¬get windowScript("Calculate Which Statistics?",gCalcCollectionValueFigures, gCalcPublisherBreakdowns, gCalcMissingDescriptions, gCalcMissingPictures, pubBreakdownDisabled,okDisabled)¬if line 1 of it <> empty then¬  put line 2 of it into gCalcCollectionValueFigures¬  put line 3 of it into gCalcPublisherBreakdowns¬  put line 4 of it into gCalcMissingDescriptions¬  put line 5 of it into gCalcMissingPictures¬  ¬  send RecalcTotals to cd 3¬  if StopIt = false then¬    if grandTotalQtyInStock > 0 then¬      put grandTotalPrice / grandTotalQtyInStock into avgPrice¬      put grandTotalCost / grandTotalQtyInStock into avgCost¬      put grandtotalCurrentYearValue / grandTotalQtyInStock into avgValue¬    else¬      put 0 into avgPrice¬      put 0 into avgCost¬      put 0 into avgValue¬    end if¬    ¬    if gCalcCollectionValueFigures then¬      put "TotalComics_Text:" & NumFormat(grandTotalQtyInStock,kIntFormatString) & return & "TotalTitles_Text:" & NumFormat(the number of cards of bg "Title",kIntFormatString) & return & "CollectionValue_Text:" & kCurrPrefix & NumFormat(grandtotalCurrentYearValue,kDecimalFormatString) & kCurrSuffix & return & "AvgValueComic_Text:" & kCurrPrefix & NumFormat(avgValue,kDecimalFormatString) & kCurrSuffix & return & "CollectionPrice_Text:" & kCurrPrefix & NumFormat(grandTotalPrice,kDecimalFormatString) & kCurrSuffix & return & "AvgPriceComic_Text:" & kCurrPrefix & NumFormat(avgPrice,kDecimalFormatString) & kCurrSuffix & return & "TotalCost_Text:" & kCurrPrefix & NumFormat(grandTotalCost,kDecimalFormatString) & kCurrSuffix & return & "AvgCostComic_Text:" & kCurrPrefix & NumFormat(avgCost,kDecimalFormatString) & kCurrSuffix & return & "TotalMarkup_Text:" & kCurrPrefix & NumFormat((grandTotalPrice - grandTotalCost),kDecimalFormatString) & kCurrSuffix & return & "AvgMarkupComic_Text:" & kCurrPrefix & NumFormat((avgPrice - avgCost),kDecimalFormatString) & kCurrSuffix & return & "TotalComics_Disabled:False" & return & "CollectionValue_Disabled:False" & return & "AvgValueComic_Disabled:False" & return & "CollectionPrice_Disabled:False" & return & "AvgPriceComic_Disabled:False" & return & "TotalCost_Disabled:False" & return & "AvgCostComic_Disabled:False" & return & "TotalMarkup_Disabled:False" & return & "AvgMarkupComic_Disabled:False" & return & "i2_Disabled:False" & return & "i5_Disabled:False" & return & "i6_Disabled:False" & return & "i7_Disabled:False" & return & "i27_Disabled:False" & return & "i28_Disabled:False" & return & "i29_Disabled:False" & return & "i40_Disabled:False" & return into theStuff¬      set the properties of window "ComicBase Statistics" to theStuff¬    end if¬    ¬    if gCalcMissingDescriptions then¬      set the properties of window "ComicBase Statistics" to "NoDescriptions_Text:" & NumFormat(gNoDescriptions,kIntFormatString) & return & "NoDescriptions_Disabled:False" & return & "i25_Disabled:False" & return & "i37_Disabled:False" & return & "i38_Disabled:False" & return¬    end if¬    ¬    if gCalcMissingPictures then¬      set the properties of window "ComicBase Statistics" to "NoPictures_Text:" & NumFormat(gNoPictures,kIntFormatString) & return & "NoPictures_Disabled:False" & return & "i17_Disabled:False" & return & "i37_Disabled:False" & return & return & "i38_Disabled:False" & return¬    end if¬    ¬    if gCalcPublisherBreakdowns then¬      set "TitlesByPublisher_Text" of window "ComicBase Statistics" to gPublisherBreakdown¬      set the properties of window "ComicBase Statistics" to "TitlesByPublisher_Disabled:False" & return & "i20_Disabled:False" & return & "i21_Disabled:False" & return & "i22_Disabled:False" & return & "i23_Disabled:False" & return & "i24_Disabled:False" & return & "i32_Disabled:False" & return¬    end if¬    ¬    put gCalcMissingDescriptions and gCalcMissingPictures and gCalcPublisherBreakdowns and gCalcCollectionValueFigures into allComputed¬    set "NotCalcMessage_Visible" of window "ComicBase Statistics" to (not (allComputed))¬  end if¬end if¬--end mouseUp¬
  170.  
  171. ItemType: TEXT
  172. Rect: 49,85,104,97
  173. TextFont: Geneva
  174. TextSize: 9
  175. Disabled: TRUE
  176. WhiteColor: -8739,-8739,-8739
  177. TextStyle: Bold
  178. Text: Pictures:
  179.  
  180. ItemType: LIST
  181. Rect: 14,126,465,248
  182. TextFont: Geneva
  183. TextSize: 9
  184. AutoSize: FALSE
  185. Disabled: TRUE
  186. GrowItem: TRUE
  187. Name: TitlesByPublisher
  188. Style: ListWithTabs...
  189. StyleInfo: ...................<.......<........<.......<.......<
  190. Logic: None
  191. Text: 
  192. Balloon: This is a breakdown of the ComicBase totals by publisher.
  193.  
  194. ItemType: TEXT
  195. Rect: 107,85,161,97
  196. TextFont: Geneva
  197. TextSize: 9
  198. AutoSize: FALSE
  199. Disabled: TRUE
  200. Name: NoPictures
  201. WhiteColor: -8739,-8739,-8739
  202. TextAlign: Right
  203. Text: 0
  204. Balloon: This is the number of different comic titles that do not have specific pictures available for them. You can get a listing of these titles by printing the statistics report (“Print” below).
  205.  
  206. ItemType: TEXT
  207. Rect: 20,114,75,126
  208. TextFont: Geneva
  209. TextSize: 9
  210. Disabled: TRUE
  211. WhiteColor: -8739,-8739,-8739
  212. TextStyle: Bold
  213. Text: Publisher
  214.  
  215. ItemType: TEXT
  216. Rect: 144,114,180,126
  217. TextFont: Geneva
  218. TextSize: 9
  219. Disabled: TRUE
  220. WhiteColor: -8739,-8739,-8739
  221. TextStyle: Bold
  222. TextAlign: Right
  223. Text: Titles
  224.  
  225. ItemType: TEXT
  226. Rect: 200,114,242,126
  227. TextFont: Geneva
  228. TextSize: 9
  229. Disabled: TRUE
  230. WhiteColor: -8739,-8739,-8739
  231. TextStyle: Bold
  232. Text: Comics
  233.  
  234. ItemType: TEXT
  235. Rect: 285,114,313,126
  236. TextFont: Geneva
  237. TextSize: 9
  238. Disabled: TRUE
  239. Name: Cost
  240. WhiteColor: -8739,-8739,-8739
  241. TextStyle: Bold
  242. Text: Cost
  243.  
  244. ItemType: TEXT
  245. Rect: 343,114,376,126
  246. TextFont: Geneva
  247. TextSize: 9
  248. Disabled: TRUE
  249. WhiteColor: -8739,-8739,-8739
  250. TextStyle: Bold
  251. Text: Value
  252.  
  253. ItemType: TEXT
  254. Rect: 27,71,104,83
  255. TextFont: Geneva
  256. TextSize: 9
  257. Disabled: TRUE
  258. WhiteColor: -8739,-8739,-8739
  259. TextStyle: Bold
  260. Text: Descriptions:
  261.  
  262. ItemType: TEXT
  263. Rect: 107,71,161,83
  264. TextFont: Geneva
  265. TextSize: 9
  266. AutoSize: FALSE
  267. Disabled: TRUE
  268. Name: NoDescriptions
  269. WhiteColor: -8739,-8739,-8739
  270. TextAlign: Right
  271. Text: 0
  272. Balloon: This is the number of different comic titles that still need to have descriptions entered for them. You can get a listing of these titles by printing the statistics report (“Print” below).
  273.  
  274. ItemType: TEXT
  275. Rect: 244,85,298,97
  276. TextFont: Geneva
  277. TextSize: 9
  278. Disabled: TRUE
  279. WhiteColor: -8739,-8739,-8739
  280. TextStyle: Bold
  281. Text: Mark-up:
  282.  
  283. ItemType: TEXT
  284. Rect: 325,27,357,39
  285. TextFont: Geneva
  286. TextSize: 9
  287. Disabled: TRUE
  288. WhiteColor: -8739,-8739,-8739
  289. TextStyle: Bold
  290. Text: Total
  291.  
  292. ItemType: TEXT
  293. Rect: 388,27,451,39
  294. TextFont: Geneva
  295. TextSize: 9
  296. Disabled: TRUE
  297. WhiteColor: -8739,-8739,-8739
  298. TextStyle: Bold
  299. Text: Avg/Comic
  300.  
  301. ItemType: TEXT
  302. Rect: 301,57,371,69
  303. TextFont: Geneva
  304. TextSize: 9
  305. AutoSize: FALSE
  306. Disabled: TRUE
  307. Name: CollectionPrice
  308. WhiteColor: -8739,-8739,-8739
  309. TextAlign: Right
  310. Text: $0.00
  311. Balloon: This is the combined asking price of all the comics in your collection.
  312.  
  313. ItemType: TEXT
  314. Rect: 381,43,450,55
  315. TextFont: Geneva
  316. TextSize: 9
  317. AutoSize: FALSE
  318. Disabled: TRUE
  319. Name: AvgValueComic
  320. WhiteColor: -8739,-8739,-8739
  321. TextAlign: Right
  322. Text: $0.00
  323. Balloon: This is the average value of each in your collection, as figured by the most current year you’ve entered price information for.
  324.  
  325. ItemType: TEXT
  326. Rect: 407,114,440,126
  327. TextFont: Geneva
  328. TextSize: 9
  329. Disabled: TRUE
  330. WhiteColor: -8739,-8739,-8739
  331. TextStyle: Bold
  332. Text: Price
  333.  
  334. ItemType: PUSH
  335. Rect: 251,266,343,286
  336. AutoSize: FALSE
  337. Name: Print…
  338. Balloon: Click here to print a report of all ComicBase statistics.
  339. Script: --on mouseUp  wdID,wdName,objNo,objName,objValue¬global gDoPreview¬¬put false into gDoPreview¬send PrintComicInfo to cd btn "PrintComicInfo" of cd 2¬--end mouseUp
  340.  
  341. ItemType: TEXT
  342. Rect: 20,248,338,260
  343. TextFont: Geneva
  344. TextSize: 9
  345. Name: NotCalcMessage
  346. BlackColor: 0,13107,-13108
  347. WhiteColor: -8739,-8739,-8739
  348. Text: Some figures may not be current. Click “Calculate…” to update them.
  349.  
  350. ItemType: LINE
  351. Rect: 20,64,115,65
  352. BlackColor: -8739,-8739,-8739
  353. WhiteColor: -4370,-4370,-4370
  354.  
  355. ItemType: BOX
  356. Rect: 14,60,171,105
  357. TextFont: Geneva
  358. TextSize: 9
  359. TextStyle: Bold
  360. BlackColor: -26215,-26215,-26215
  361. WhiteColor: -8739,-8739,-8739
  362. Name: Titles Without…
  363.  
  364. ItemType: LBL
  365. Rect: 24,57,114,69
  366. TextFont: Geneva
  367. TextSize: 9
  368. TextStyle: Bold
  369. Disabled: TRUE
  370. WhiteColor: -8739,-8739,-8739
  371. Text: Titles Without…
  372.  
  373. ItemType: BOX
  374. Rect: 206,20,465,105
  375. TextFont: Geneva
  376. TextSize: 9
  377. TextStyle: Bold
  378. BlackColor: -26215,-26215,-26215
  379. WhiteColor: -8739,-8739,-8739
  380. Name: Valuation
  381.  
  382. ItemType: LINE
  383. Rect: 202,24,271,25
  384. BlackColor: -8739,-8739,-8739
  385. WhiteColor: -4370,-4370,-4370
  386.  
  387. ItemType: LBL
  388. Rect: 216,17,270,29
  389. TextFont: Geneva
  390. TextSize: 9
  391. TextStyle: Bold
  392. Disabled: TRUE
  393. WhiteColor: -8739,-8739,-8739
  394. Text: Valuation
  395.  
  396. ItemType: PUSH
  397. Rect: 151,266,243,286
  398. AutoSize: FALSE
  399. Name: Preview…
  400. Balloon: Click here to print a report of all ComicBase statistics.
  401. Script: --on mouseUp  wdID,wdName,objNo,objName,objValue¬global gDoPreview¬¬put true into gDoPreview¬send PrintComicInfo to cd btn "PrintComicInfo" of cd 2¬--end mouseUp